package itheima.com.Test;

import java.io.FileReader;
import java.io.IOException;
import java.util.Properties;

public class PropertiesTest6 {
    public static void main(String[] args) throws IOException {
        Properties properties = new Properties();

       /* properties.setProperty("小狗","哈巴");
        properties.setProperty("小猪","皮皮");
        properties.setProperty("小猴","吉吉");*/

      /*  properties.put("胡歌","34");
        properties.put("陈晓","31");
        properties.put("古天乐","52");

        FileWriter fw =new FileWriter("ggd.properties");
        properties.store(fw,"第一次创建的properties");
        fw.close();*/

        FileReader fr = new FileReader("ggd.properties");
        properties.load(fr);
        fr.close();
        System.out.println(properties);
    }
}
